1. Field of the Invention
The present invention relates to the field of computer systems. Specifically, the present invention relates to the field of preserving the processing state of computer system having a volatile form of memory and/or registers.
2. Related Art
Computer systems encounter many situations where some level of system state preservation is necessary. Several examples of such situations include basic interrupt processing, context switching, and low power operations. Basic interrupt processing involves the suspension of processing at a first location and transfer of processing to a second location upon the occurrence of some interrupting event. Prior to transfer to the second location, several system and processor parameters and registers (collectively known as processor state) are preserved by being pushed onto a stack typically located in random access memory (RAM). Upon return from the interrupt, the processor state may be popped from the stack and processing control may return to a position following the location at which the interrupt occurred. In the basic interrupt model, processor state information is saved and restored; however, the entire system state including the contents of memory and the condition of system resources and peripherals is not saved. Moreover, the use of a stack in RAM for retention of processor state during a basic interrupt does not provide protection against the loss of power to the random access memory sub-system.
Many multi-tasking and multi-user systems use a technique called context switching for transferring processing control from one task or user (collectively known as a process) to a different process. Each process operates within a processing environment or context defined by a number of parameters, registers, and/or regions of random access memory associated with that process. Prior to switching from a first process to a second process, the context associated with the first process is preserved and the context associated with the second process is retrieved. Context information is typically stored in a stack in random access memory. Similar to the situation with basic interrupt processing, the preservation of system state for context switching does not save the entire state of the computer system in a nonvolatile form.
Some computer systems with un-interruptable power supplies (UPS) use system state preservation techniques thereby allowing the computer system to ride through a low power condition or power outage. These state preservation techniques in UPS applications typically involve a graceful shut-down of the computer system rather than an attempt to freeze the processing state of the computer system at a particular moment in time. Thus, UPS-oriented state preservation techniques do not allow a user to continue operation of the computer system from where he/she was interrupted just prior to the loss of power.
Still other computer systems employ additional hardware or external hardware for the purpose of preserving the computer system state. Such systems reserve a portion of memory and/or dedicate a set of processor registers for the purpose of performing the state preservation function. Other system have dedicated hardware channels, interfaces, or system resources used only during the state preservation operation.
One reason why preservation of computer system state is so difficult is because any process of preserving the computer system state that uses computer system resources such as memory, processor, or a mass storage device, must use these resources without destroying the context or environment in which they were previously operating. Thus, a state preservation process must share system resources without permanently altering their state. This constraint has been particularly difficult to satisfy in small computer systems such as personal computers, laptop computers or notebook computers. Personal computer systems typically operate with a wide variety of different software application programs. These application programs often control, manipulate, or modify many if not all of the computer system resources available. It is often not possible to anticipate much less constrain the operation of application programs to a particular pre-defined resource domain. Therefore, reserving system resources for a state preservation process is often not feasible. Moreover, the low cost and competitive nature of personal computers often does not justify the addition of additional hardware dedicated to a state preservation function.
The operation of a state preservation process is made more difficult by the increased level of sophistication of hardware in modern personal computer systems. In the past, an entire computer system state could be completely defined by the content of memory and a few processor registers. Now, however, the computer system is more widely distributed throughout various resources of the system. In addition, computer system memory is now partitioned into more than one section that may not always be directly addressable by the processor. It has therefore become increasingly difficult to effectively preserve and restore the processing state in these sophisticated computer systems.
Thus, a better process and means is needed for preserving and restoring the processing state of the computer system.